import java.util.Arrays;
import java.util.Scanner;


public class Main {
    public static void main1(String[] args) {
        Scanner sc = new Scanner(System.in);
        while(sc.hasNext()) {
            int n = sc.nextInt();
            int t = sc.nextInt();
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = sc.nextInt();
            }
            Arrays.sort(arr);
            int res = 0;
            int pre = 0;
            for (int i = 0; i < n; i++) {
                if(arr[i] < t) {
                    res++;
                }else if(pre==0) {
                    pre = arr[i];
                }else if(pre+n>arr[i]) {
                    res++;
                }else if(pre+t == arr[i]){
                    pre=arr[i];
                }
            }
            System.out.println(res);
        }
    }
}
